package com.android.newsreader;

/**
* Class for representing an RSS Item
*  
*/
public class RSSItem 
{
	private String mTitle = null;
	private String mDescription = null;
	private String mLink = null;
	private String mCategory = null;
	private String mPubdate = null;

	
	public RSSItem()
	{
	}
	
	public void setTitle(String title)
	{
		mTitle = title;
	}
	
	public void setDescription(String description)
	{
		mDescription = description;
	}
	
	public void setLink(String link)
	{
		mLink = link;
	}
	
	public void setCategory(String category)
	{
		mCategory = category;
	}
	
	public void setPubDate(String pubdate)
	{
		mPubdate = pubdate;
	}
	
	public String getTitle()
	{
		return mTitle;
	}
	
	public String getDescription()
	{
		return mDescription;
	}
	
	public String getLink()
	{
		return mLink;
	}
	
	public String getCategory()
	{
		return mCategory;
	}
	
	public String getPubDate()
	{
		return mPubdate;
	}
	
	public String toString()
	{
		// limit how much text we display
		if (mTitle.length() > 42)
		{
			return mTitle.substring(0, 42) + "...";
		}
		return mTitle;
	}
}
